if exists (select 1
            from  sysobjects
           where  id = object_id('bd_sys_maxId')
            and   type = 'U')
   drop table bd_sys_maxId
go

/*==============================================================*/
/* Table: bd_sys_maxId                                          */
/*==============================================================*/
create table bd_sys_maxId (
   tableName            VARCHAR(50)          not null,
   maxId                int                  not null,
   constraint PK_BD_SYS_MAXID primary key (tableName)
)
go
